Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comment seems not searchable #120

Closed
Robin2009 opened this issue Feb 11, 2014 · 10 comments
Closed

Comment seems not searchable #120

Robin2009 opened this issue Feb 11, 2014 · 10 comments
Labels

Comments

@Robin2009
Copy link

Hi all,
Now I met a very interest problem about this plugin.It seems that the comments below the tag ~~DISCUSSION~~ are not searchable,which means , if I use any word contained in the comments as a key word I will get nothing expected returned by dokuwiki. Can someone give a hand ? Because it's really make sense to me to be able to find those comments through the searching.

@Robin2009
Copy link
Author

Anybody there ? Do I misconfig something or that is exectly how things going for the comments of the discussion? If so, what should I do to make those comments searchable?

@michitux
Copy link
Member

Comments should be searchable (automatically), I don't know why it doesn't work for you. Are you using the current version of the discussion plugin? Does the search for the content of these pages work? I can't reproduce your problem, in my DokuWiki installation I can search for words that are (only) in the comments.

@Robin2009
Copy link
Author

Hi michtux,
Thanks for your feedback since this problem's puzzling me so much recently. I'm so sure that the search for the content works well of these pages.Plus ,another thing seems weird for me is I did see those commends in those pages, but after I clicked the edit button, there's nothing after the tag ,none of those commends there.I guess that's the reason why those commends are not searchable maybe?

@Robin2009
Copy link
Author

Oki...I found reason...it looks like that only the english words in commends are searchable. I did a test like writing a reply using both english and chinese charcters , when I searched by those english words dokuwiki gave me a perfect result, but it found nothing when I use any chinese word as a keyword :( But most of those articles are in Chinese, what could I do to fix that problem?

@michitux
Copy link
Member

The comments are stored in an extra file and not in the page itself and added to the search by the discussion plugin. However for the search index it should be as if the comments were in the page itself. I don't know why chinese words don't work. Can you search for chinese words in the page itself?

@Robin2009
Copy link
Author

Yeah,works for any chinese word contained page. @@!

@Robin2009
Copy link
Author

"谢谢",here you can take this chinese word for testing. BTW,the word means "Thank you". :)

@michitux
Copy link
Member

Okay, I found the problem. This is actually a bug of DokuWiki that can't be solved in the discussion plugin without replacing the whole search function. I've opened a bug report in the DokuWiki bug tracker.

Basically what happens is that DokuWiki indexes this word as two words and also splits the search query into two words/a phrase. As DokuWiki doesn't store in the index if these words actually occur together, it checks against the page content (and not the content of the comments) if they appear together.

If you search for just one of the two symbols or put a space between them, you'll also get results for comments. I'll have a look at this problem in DokuWiki itself during our bug hunting day this saturday.

@Robin2009
Copy link
Author

I tried again using one chinese word with spaces between each characters and yes, you're right.I thought it's because the chinese words were encoded in UTF-8 so that the doku's seach engine could not deal with the chinese key words in search box...Ok,anyhow I'm so glad to see that the problem was confirmed by someone. Thank you michitux ! So ...... seems the only thing I can do now is waiting for the new version of Dokuwiki ?! Again, appreciate your help so much!

@Klap-in Klap-in added the bug label Nov 5, 2014
@Klap-in
Copy link
Member

Klap-in commented Nov 5, 2014

This is fixed in DokuWiki as well.

@Klap-in Klap-in closed this as completed Nov 5, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants